///<reference path="./common/vscodeapi.d.ts"/>
import * as DOM from "./functions/dom/domtool.js";
//import { Tool_AtlasPackInit } from "./editor_atlaspack/atlaspack.js";
import { IO, TTPathTool } from "./common/io.js";
import { Tool_AniPreviewerInit } from "./editor_anipreviewer/anipreviewer.js";


window.onload = async () => {
    IO.Init();//初始化扩展IO系统

    let filename = IO.GetEditFileName();
    console.log("argv:" + filename);
    let ext = TTPathTool.GetExt(filename);
    if (ext == ".ttani.json" ) {
        console.log("这是一个动画文件");
        Tool_AniPreviewerInit();
    }
    else {
        DOM.DomTool.Init();
        DOM.DomTool.AddLabel("不支持的文件:" + filename);
        console.log("不支持的文件");
        return;
    }


}
